import {
	service
} from "../utils/request";


export class APIJS {
	// 发送验证码
	static async sendMsg(params) {
		return service({
			url: '/AppLogin/sendMsg',
			method: 'post',
			data: params
		})
	};
	// 登录
	static async validCode(params) {
		return service({
			url: '/AppLogin/validCode',
			method: 'post',
			data: params
		})
	};
	// 推出
	static async loginOut(params) {
		return service({
			url: '/AppLogin/loginOut',
			method: 'post',
			data: params
		})
	};
	
	
	// 分页分类列表
	static async getCategoryList(params) {
		return service({
			url: '/appApi/getCategoryList',
			method: 'get',
			// params: params
		})
	};
	
	
	// 查列表
	static async getStandardContentList(params) {
	
		return service({
			url: `/appApi/getStandardContentList?category=${params.category}&pageIndex=${params.pageIndex}&pageSize=${params.pageSize}&searchKey=${params.searchKey}`,
			method: 'get',
			// params: params
		})
	};
	
	

// 搜索查列表
	static async qryStandardContentList(params) {
		return service({
			url: `/appApi/qryStandardContentList?pageIndex=${params.pageIndex}&pageSize=${params.pageSize}&searchKey=${params.searchKey}&type=${params.type}`,
			method: 'get',
			// params: params
		})
	};
	
	
	// 查详情
	static async getStandardContentById(params) {
		return service({
			url: `/appApi/getStandardContentById?id=${params.id}`,
			method: 'get',
			// params: params
		})
	};
	
	
	
	// 加入书签
	static async bookmarkAdd(params) {
		return service({
			url: '/bookmark/add',
			method: 'post',
			data: params
		})
	};
	// 删除书签
	static async delBookmark(params) {
		return service({
			url: `/bookmark/delBookmark?id=${params.id}`,
			method: 'get',
			// params: params
		})
	};
	// 删除书签
	static async getBookmarkDetail(params) {
		return service({
			url: `/bookmark/getBookmarkDetail?id=${params.id}`,
			method: 'get',
			// params: params
		})
	};
	
	// 获取书签列表
	static async getUserBookmarkList(params) {
		return service({
			url: '/bookmark/getUserBookmarkList',
			method: 'post',
			data: params
		})
	};
	
	
	
	
	
	// 意见反馈
	static async addFeedback(params) {
		return service({
			url: '/appApi/addFeedback',
			method: 'post',
			data: params
		})
	};
	
	
	// 注销用户
	static async delUser(params) {
		return service({
			url: '/AppLogin/delUser',
			method: 'post',
			data: params
		})
	};


}
